package com.xuan.factory.staticfactory;


public class Computer implements Device {
    // 构造器私有
    private Computer() {}

    // 静态工厂方法
    public static Device createComputer() {
        return new Computer();
    }
    @Override
    public void produce() {
        System.out.println("电脑");
    }
}
